package tech.heptagram.staff.cas.domain.info;

import com.fasterxml.jackson.annotation.JsonIgnoreProperties;

import java.util.List;
import java.util.Set;

import lombok.Data;

/**
 * Created by yang on 2017/7/6.
 */
@Data
@JsonIgnoreProperties(value = {"handler"})
public class MenuTreeVo {
    private Integer id;
    private String text;
    private String path;
    private Integer type;
    private Integer parentId;
    private Integer viewOrder;
    private List<MenuTreeVo> children;
    private Set<MenuTreeVo> child;
    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        MenuTreeVo that = (MenuTreeVo) o;

        return id.equals(that.id);
    }

    @Override
    public int hashCode() {
        return id.hashCode();
    }
}
